﻿@model IUserAccountViewModel
@{
    Layout = null;
}
<!DOCTYPE html>
<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>login</title>
</head>
<body>
    @using (Html.BeginForm())
    {
        <div>
            @Html.ValidationSummary()
            <fieldset>
                <legend>Registration Form</legend>
                <ol>
                    <li>
                        @Html.LabelFor(m => m.Item.Name)
                        @Html.TextBoxFor(m => m.SearchParam.Name, new { id = "Name" })
                    </li>
                    <li>
                        @Html.LabelFor(m => m.Item.Password)
                        @Html.PasswordFor(m => m.SearchParam.Password, new { id = "Password" })
                    </li>
                </ol>
                <input type="submit" value="登录" id="submit" />
            </fieldset>
        </div>
    }
    @Scripts.Render("~/bundles/jquery")
    @Scripts.Render("~/bundles/jqueryval")
    <script type="text/javascript">
        $(function () {
            $("form[action$='login']").submit(function () {
                $.post($(this).attr("action"), $(this).serialize(), function (response) {
                });

                return true;
            });
        })
    </script>
</body>
</html>
